/*
 * XML Type:  AbstractTaxW2
 * Namespace: http://ofx.net/types/2003/04
 * Java type: net.ofx.types.x2003.x04.AbstractTaxW2
 *
 * Automatically generated - do not modify.
 */
package net.ofx.types.x2003.x04.impl;
/**
 * An XML AbstractTaxW2(@http://ofx.net/types/2003/04).
 *
 * This is a complex type.
 */
public class AbstractTaxW2Impl extends org.apache.xmlbeans.impl.values.XmlComplexContentImpl implements net.ofx.types.x2003.x04.AbstractTaxW2
{
    
    public AbstractTaxW2Impl(org.apache.xmlbeans.SchemaType sType)
    {
        super(sType);
    }
    
    private static final javax.xml.namespace.QName TAXYEAR$0 = 
        new javax.xml.namespace.QName("", "TAXYEAR");
    private static final javax.xml.namespace.QName CNTRLNO$2 = 
        new javax.xml.namespace.QName("", "CNTRLNO");
    private static final javax.xml.namespace.QName VOID$4 = 
        new javax.xml.namespace.QName("", "VOID");
    
    
    /**
     * Gets the "TAXYEAR" element
     */
    public java.util.Calendar getTAXYEAR()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(TAXYEAR$0, 0);
            if (target == null)
            {
                return null;
            }
            return target.getCalendarValue();
        }
    }
    
    /**
     * Gets (as xml) the "TAXYEAR" element
     */
    public net.ofx.types.x2003.x04.YearType xgetTAXYEAR()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.YearType target = null;
            target = (net.ofx.types.x2003.x04.YearType)get_store().find_element_user(TAXYEAR$0, 0);
            return target;
        }
    }
    
    /**
     * Sets the "TAXYEAR" element
     */
    public void setTAXYEAR(java.util.Calendar taxyear)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(TAXYEAR$0, 0);
            if (target == null)
            {
                target = (org.apache.xmlbeans.SimpleValue)get_store().add_element_user(TAXYEAR$0);
            }
            target.setCalendarValue(taxyear);
        }
    }
    
    /**
     * Sets (as xml) the "TAXYEAR" element
     */
    public void xsetTAXYEAR(net.ofx.types.x2003.x04.YearType taxyear)
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.YearType target = null;
            target = (net.ofx.types.x2003.x04.YearType)get_store().find_element_user(TAXYEAR$0, 0);
            if (target == null)
            {
                target = (net.ofx.types.x2003.x04.YearType)get_store().add_element_user(TAXYEAR$0);
            }
            target.set(taxyear);
        }
    }
    
    /**
     * Gets the "CNTRLNO" element
     */
    public java.lang.String getCNTRLNO()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(CNTRLNO$2, 0);
            if (target == null)
            {
                return null;
            }
            return target.getStringValue();
        }
    }
    
    /**
     * Gets (as xml) the "CNTRLNO" element
     */
    public net.ofx.types.x2003.x04.ControlNumber xgetCNTRLNO()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.ControlNumber target = null;
            target = (net.ofx.types.x2003.x04.ControlNumber)get_store().find_element_user(CNTRLNO$2, 0);
            return target;
        }
    }
    
    /**
     * True if has "CNTRLNO" element
     */
    public boolean isSetCNTRLNO()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().count_elements(CNTRLNO$2) != 0;
        }
    }
    
    /**
     * Sets the "CNTRLNO" element
     */
    public void setCNTRLNO(java.lang.String cntrlno)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(CNTRLNO$2, 0);
            if (target == null)
            {
                target = (org.apache.xmlbeans.SimpleValue)get_store().add_element_user(CNTRLNO$2);
            }
            target.setStringValue(cntrlno);
        }
    }
    
    /**
     * Sets (as xml) the "CNTRLNO" element
     */
    public void xsetCNTRLNO(net.ofx.types.x2003.x04.ControlNumber cntrlno)
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.ControlNumber target = null;
            target = (net.ofx.types.x2003.x04.ControlNumber)get_store().find_element_user(CNTRLNO$2, 0);
            if (target == null)
            {
                target = (net.ofx.types.x2003.x04.ControlNumber)get_store().add_element_user(CNTRLNO$2);
            }
            target.set(cntrlno);
        }
    }
    
    /**
     * Unsets the "CNTRLNO" element
     */
    public void unsetCNTRLNO()
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_element(CNTRLNO$2, 0);
        }
    }
    
    /**
     * Gets the "VOID" element
     */
    public net.ofx.types.x2003.x04.BooleanType.Enum getVOID()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(VOID$4, 0);
            if (target == null)
            {
                return null;
            }
            return (net.ofx.types.x2003.x04.BooleanType.Enum)target.getEnumValue();
        }
    }
    
    /**
     * Gets (as xml) the "VOID" element
     */
    public net.ofx.types.x2003.x04.BooleanType xgetVOID()
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.BooleanType target = null;
            target = (net.ofx.types.x2003.x04.BooleanType)get_store().find_element_user(VOID$4, 0);
            return target;
        }
    }
    
    /**
     * True if has "VOID" element
     */
    public boolean isSetVOID()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().count_elements(VOID$4) != 0;
        }
    }
    
    /**
     * Sets the "VOID" element
     */
    public void setVOID(net.ofx.types.x2003.x04.BooleanType.Enum xvoid)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_element_user(VOID$4, 0);
            if (target == null)
            {
                target = (org.apache.xmlbeans.SimpleValue)get_store().add_element_user(VOID$4);
            }
            target.setEnumValue(xvoid);
        }
    }
    
    /**
     * Sets (as xml) the "VOID" element
     */
    public void xsetVOID(net.ofx.types.x2003.x04.BooleanType xvoid)
    {
        synchronized (monitor())
        {
            check_orphaned();
            net.ofx.types.x2003.x04.BooleanType target = null;
            target = (net.ofx.types.x2003.x04.BooleanType)get_store().find_element_user(VOID$4, 0);
            if (target == null)
            {
                target = (net.ofx.types.x2003.x04.BooleanType)get_store().add_element_user(VOID$4);
            }
            target.set(xvoid);
        }
    }
    
    /**
     * Unsets the "VOID" element
     */
    public void unsetVOID()
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_element(VOID$4, 0);
        }
    }
}
